// components/activitiesColumn/activitiesColumn.js
Component({
  /**
   * 组件的属性列表
   */
  properties: {
    activities:{
      type: Object,
      value: {}
    }
  },
  attached: function () {
    // console.log('1234567',this.data)  
  },
  /**
   * 组件的初始数据
   */
  data: {

  },

  /**
   * 组件的方法列表
   */
  methods: {
    toActivity() {
      console.log(this.properties.activities)
      switch(this.properties.activities.type) {
        case 'TEACHING_RESEARCH':
          wx.navigateTo({
            url: '/packageA/pages/researchDetail/researchDetail?activityId=' + this.properties.activities.activityId
          })
          break
        case 'LIVE_BORADCAST':
          wx.navigateTo({
            url: '/packageA/pages/liveDetails/liveDetails?activityId=' + this.properties.activities.activityId
          })
          break
        case 'PREPARE_LESSON':
          wx.navigateTo({
            url: '/packageA/pages/prepareLessonsDetails/prepareLessonsDetails?activityId=' + this.properties.activities.activityId
          })
          break
      }
    }
  }
})
